function ID_idcOpen(){       //打开ID卡读卡器
 	var idcopen = ZKJCStdEqpt.idcOpen();
	return idcopen;
}
function ID_idcScanAsyn(){    //等待扫描ID卡
   var idcscanasyn = ZKJCStdEqpt.idcScanAsyn(40*1000);
	return idcscanasyn;
}

function ID_idcGetIdNum()  //异步读取ID卡号
{
	var idcIdNum = ZKJCStdEqpt.GetIdCardNumber();
	return idcIdNum;
}
function ID_ReadIDCard(){     //读取ID卡号
  var readidcard = ZKJCStdEqpt.IdcCardNumber;
	return readidcard;
}
function ID_idcClose(){       //关闭ID卡读卡器
  var idcclose = ZKJCStdEqpt.idcClose();
	return idcclose;
}

var IDCardnum;
function getID() {
	return IDCardnum;
}
var whereuse; //判断哪个程序调用readNUM

function showNum(){
      if(whereuse == 1){
       var x=Baoshang.showNum();
      } else if(whereuse == 6){
      var x=BOCSuzhou.showNums();
      }
}

 // 输入密码
 
 
 function choosewhere(i){
    whereuse =i;
 }
 
 function pinpadOpen(){
	var result = ZKJCStdEqpt.pinpadOpen(0);
	return result;
}
function pinpadInit(){   //强制初始化
     var pintInit=ZKJCStdEqpt.pinpadInit();
     return pintInit;
}
function beginInput0(){
	var result = ZKJCStdEqpt.pinpadBeginRead(40, 0, 0);
//	alert(result);
	return result;
}
function beginInput1(){
	var result = ZKJCStdEqpt.pinpadBeginRead(40, 0, 0);
//	alert(result);
	return result;
}

function endInput(){
    var result = ZKJCStdEqpt.pinpadEndRead(0);
   return result;
}

function readNum(){
	if(whereuse == 1){
	    var x= Baoshang.readNum();
	}else if(whereuse == 2){
	    var x = Maintain.readNums();
	} else if(whereuse == 6) {
		var x = BOCSuzhou.readNums();
	}else if(whereuse == 5){
	var x =MainTainBS.readNums();
	}
 }

var ascNum;
function getNum(){
  return ascNum;
}
function inputNum(key){
 var s = ZKJCStdEqpt.pinpadMapKey(key);
 return s;
}

function closePinpad() {
   var c = ZKJCStdEqpt.pinpadClose();
   return c;
}
//============身份证阅读器模块===============

//打开身份证阅读器
function openIDReader() {
	var openID = ZKJCStdEqpt.idsOpen(0);
	return openID;
}

//关闭身份证阅读器
function closeIDReader() {
	var closeID = ZKJCStdEqpt.idsClose();
	return closeID;
} 

//等待扫描身份证
function waitScanID() {
	var scanID = ZKJCStdEqpt.idsInsertAsyn(30*1000);
	return scanID;
}

//读取身份证扫描信息
function scanResultID(type) {
	var scanResult = ZKJCStdEqpt.idsRead(type);
	return scanResult;
}

//flex回调
function getIDInfo() {
	var x = BOCSuzhou.IDInfo();
}


//=========等待超时=========
function timeover() {
	if(whereuse == 1){
	    var x= Baoshang.timeout();
	}else if(whereuse == 2){
	    var x = Maintain.timeout();
	} else if(whereuse == 6) {
		var x = BOCSuzhou.timeout();
	}
}





